/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.sales.client;

import br.com.sales.generics.client.inject.MyMainLayoutModule;
import br.com.sales.generics.client.nametoken.NameTokens;
import br.com.sales.generics.client.place.DefaultPlace;
import br.com.sales.generics.client.place.LoginPlace;
import br.com.sales.generics.client.place.Place;
import br.com.sales.hancadpe.client.injector.HanCadPEModule;
import br.com.sales.hancadpo.client.injector.HanCadPOModule;
import br.com.sales.hancadsa.client.injector.HanCadSAModule;
import br.com.sales.hancadso.client.injector.HanCadSOModule;
import br.com.sales.hanforpi.client.injector.HanForPIModule;
import br.com.sales.hanhishi.client.injector.HanHisHIModule;
import com.gwtplatform.mvp.client.gin.AbstractPresenterModule;
import com.gwtplatform.mvp.client.gin.DefaultModule;
import com.gwtplatform.mvp.shared.proxy.RouteTokenFormatter;

/**
 *
 * @author v
 */
public class MainGinModule extends AbstractPresenterModule {

    @Override
    protected void configure() {
        install(new DefaultModule.Builder()
                .placeManager(Place.class)
                .tokenFormatter(RouteTokenFormatter.class)
                .build());
        bindConstant().annotatedWith(LoginPlace.class).to(NameTokens.LOGIN);
        bindConstant().annotatedWith(DefaultPlace.class).to(NameTokens.CONTROLLER);

        install(new MyMainLayoutModule());
        install(new HanForPIModule());
        install(new HanHisHIModule());
        install(new HanCadPOModule());
        install(new HanCadSAModule());
        install(new HanCadPEModule());
        install(new HanCadSOModule());
    }

}
